package com.news.service;

import java.util.List;

import com.news.dao.NewsDao;
import com.news.entity.News;
import com.news.util.PageModel;

public interface NewsService {

	public abstract void setNewsDao(NewsDao newsDao);

	public abstract List<News> getAllNews(Integer currentPage, Integer rows);

	public abstract PageModel getPageModel(Integer currentPage, Integer rows);

	public abstract List<News> getAllNewsByPid(Integer currentPage,
			Integer rows, int pid);

	public abstract PageModel getPageModelByPid(Integer currentPage,
			Integer rows, int pid);

	public abstract void addNews(News news);

	public abstract boolean delNews(int newsid);

	public abstract News getNews(int newsid);

	public abstract boolean updateNews(News news);

}